package com.homework.service;

import java.sql.SQLException;

import com.homework.bean.CourseBean;
import com.homework.bean.InformBean;
import com.homework.bean.PageInfoBean;
import com.homework.bean.UserBean;
import com.homework.bean.UserInformListBean;
import com.homework.dao.InformDao;

public class InformService {
	private static InformService informService;
	private static InformDao informDao;

	public InformService() {
		informDao = new InformDao();
	}

	public static InformService getInstance() {
		if (informService == null) {
			informService = new InformService();
		}
		return informService;
	}

	// 通知列表
	public UserInformListBean informShow(CourseBean courseBean,
			PageInfoBean pageInfoBean) throws SQLException {
		return informDao.informShow(courseBean, pageInfoBean);
	}
	
	// 发布通知
	public void informAdd(CourseBean courseBean,UserBean userBean,InformBean informBean){
		informDao.informAdd(courseBean,userBean,informBean);
	}
}
